$OpenBSD: patch-src_libsodium_Makefile_in,v 1.1 2017/03/20 22:32:11 sthen Exp $

Adapted from Makefile.am patch:

From 2e1106ed642ea150d4a9df4b215317e8b536ea5e Mon Sep 17 00:00:00 2001
From: Frank Denis <github@pureftpd.org>
Date: Mon, 20 Mar 2017 15:46:49 +0100
Subject: [PATCH] Require @CFLAGS_SSE2@ to build libaesni

Fixes compilation on OpenBSD/i386 with the base gcc compiler.

--- src/libsodium/Makefile.in.orig	Mon Mar 20 22:27:57 2017
+++ src/libsodium/Makefile.in	Mon Mar 20 22:28:07 2017
@@ -881,7 +881,7 @@ libsodium_la_LIBADD = libaesni.la libsse2.la libssse3.
 noinst_LTLIBRARIES = libaesni.la libsse2.la libssse3.la libsse41.la libavx2.la
 libaesni_la_LDFLAGS = $(libsodium_la_LDFLAGS)
 libaesni_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \
-	@CFLAGS_SSSE3@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@
+	@CFLAGS_SSE2@ @CFLAGS_SSSE3@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@
 
 libaesni_la_SOURCES = \
 	crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c
